package com.ruoyi.student.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.student.mapper.StudentsCollegesMapper;
import com.ruoyi.student.domain.StudentsColleges;
import com.ruoyi.student.service.IStudentsCollegesService;

/**
 * 二级学院信息Service业务层处理
 *
 *
 * @date 2024-04-16
 */
@Service
public class StudentsCollegesServiceImpl implements IStudentsCollegesService
{
    @Autowired
    private StudentsCollegesMapper studentsCollegesMapper;

    /**
     * 查询二级学院信息
     *
     * @param collegeId 二级学院信息主键
     * @return 二级学院信息
     */
    @Override
    public StudentsColleges selectStudentsCollegesByCollegeId(Long collegeId)
    {
        return studentsCollegesMapper.selectStudentsCollegesByCollegeId(collegeId);
    }

    /**
     * 查询二级学院信息列表
     *
     * @param studentsColleges 二级学院信息
     * @return 二级学院信息
     */
    @Override
    public List<StudentsColleges> selectStudentsCollegesList(StudentsColleges studentsColleges)
    {
        return studentsCollegesMapper.selectStudentsCollegesList(studentsColleges);
    }

    /**
     * 新增二级学院信息
     *
     * @param studentsColleges 二级学院信息
     * @return 结果
     */
    @Override
    public int insertStudentsColleges(StudentsColleges studentsColleges)
    {
        return studentsCollegesMapper.insertStudentsColleges(studentsColleges);
    }

    /**
     * 修改二级学院信息
     *
     * @param studentsColleges 二级学院信息
     * @return 结果
     */
    @Override
    public int updateStudentsColleges(StudentsColleges studentsColleges)
    {
        return studentsCollegesMapper.updateStudentsColleges(studentsColleges);
    }

    /**
     * 批量删除二级学院信息
     *
     * @param collegeIds 需要删除的二级学院信息主键
     * @return 结果
     */
    @Override
    public int deleteStudentsCollegesByCollegeIds(Long[] collegeIds)
    {
        return studentsCollegesMapper.deleteStudentsCollegesByCollegeIds(collegeIds);
    }

    /**
     * 删除二级学院信息信息
     *
     * @param collegeId 二级学院信息主键
     * @return 结果
     */
    @Override
    public int deleteStudentsCollegesByCollegeId(Long collegeId)
    {
        return studentsCollegesMapper.deleteStudentsCollegesByCollegeId(collegeId);
    }
}
